/*LICENSE_BEGIN
 * ******************************************************************
 * All original parts of SoccerScope2003 have copyright (2003) by
 * Team YowAI, represented by Mr. Shuhei Shiota
 * The Department of Creative Informatics
 * The Graduate School of Information Science and Technology
 * The University of Tokyo
 * 
 * Additional classes (except libraries in /lib) were developed by 
 * the Dainamite Robocup-Team of the DAI-Labor, TU-Berlin 
 * (www.dai-labor.de)
 * 
 * Extended/new classes/packages are:
 *   soccerscope.analyzer.LogfileAnalyzer
 *   soccerscope.daistatistic.*
 *   soccerscope.daistatistic.charts.*
 *   soccerscope.daistatistic.tools.*
 *   soccerscope.db.*
 *   soccerscope.dialog.*
 *   soccerscope.model.PlayerWorldModel
 *   soccerscope.model.SimplePlayer
 *   soccerscope.net.AgentConnector
 *   soccerscope.training.*
 *   soccerscope.training.conditions.*
 * ******************************************************************
LICENSE_END*/
package soccerscope.model;

import java.io.Serializable;

public class Team implements Serializable {
    /**
     * id for serialization. 
     */
    private static final long serialVersionUID = 3256726186435426101L;

    public final static int LEFT_SIDE = 1;

	public final static int NEUTRAL = 0;

	public final static int RIGHT_SIDE = -1;

	public String name;

	public int score;

	public float offsideline;

	public boolean offside;

	public Team() {
		this.name = "";
		this.score = 0;
		this.offsideline = 0.0f;
		this.offside = false;
	}

	public Team(Team team) {
		this.name = new String(team.name);
		this.score = team.score;
		this.offsideline = team.offsideline;
		this.offside = team.offside;
	}

	public Team(String name, int score, int side) {
		this.name = new String(name);
		this.score = score;
		this.offsideline = 0.0f;
		this.offside = false;
	}

	public Team(int side) {
		this.score = 0;
		this.offsideline = 0.0f;
		this.offside = false;

		if (side == LEFT_SIDE) {
			this.name = "left";
		} else if (side == NEUTRAL) {
			this.name = "";
		} else if (side == RIGHT_SIDE) {
			this.name = "right";
		}
	}
}
